﻿<%@ Page Title="" Language="C#" MasterPageFile="~/Site.Master" AutoEventWireup="true" CodeBehind="AdminForProductUpload.aspx.cs" Inherits="FYPHP.AdminForProductUpload" %>
<asp:Content ID="Content1" ContentPlaceHolderID="HeadContent" runat="server">
</asp:Content>
<asp:Content ID="Content2" ContentPlaceHolderID="LeftContent" runat="server">
</asp:Content>
<asp:Content ID="Content3" ContentPlaceHolderID="MainContent" runat="server">
    <br />
    
    <br />
    <br />
            <asp:Repeater ID="ItemList" runat="server"  onitemcommand="rptAds_ItemCommand" 
                EnableViewState="False">
                <HeaderTemplate>
                    <table cellpadding="5" cellspacing="5" width="722" border="1px solid #ffffff" 
                        align="center" 
                        
                        style="border-collapse: collapse; border-color: #aaaaaa; text-align: center">
                        <tr style="background-color: #eee; font-weight: bold;">
                            <td>
                                Picture</td>
                            <td>
                                Product Name</td>
                            <td>
                                View Product</td>
                   
                        </tr>
                </HeaderTemplate>
                <ItemTemplate>
                    <tr>
                        <td align="center" width="50">
                            <img src="\uploads\products\<%#DataBinder.Eval(Container.DataItem, "p_picture" ) %>" alt="" height="40px" width="40px" />
                        </td>
                        <td style="text-align: left">
                            <a href="/ProductDetails.aspx?id=<%#DataBinder.Eval(Container.DataItem, "p_id" ) %>">
                            <%#DataBinder.Eval(Container.DataItem, "p_name" ) %></a>
                            <br />
                            <i style="font-size:11px;"><%#DataBinder.Eval(Container.DataItem, "p_desc" ) %>
                            </i>
                        </td>
                         <td><asp:Button ID="btnView" runat="server" 
                                 Text="View Product" CommandName="ViewProduct" 
        CommandArgument='<%# Eval("p_id").ToString() %>' />

            </td>
                  
                    </tr>
                </ItemTemplate>
                <FooterTemplate>
                    </table>
                </FooterTemplate>
            </asp:Repeater>
    <br />
    <br />
    <br />
    <br />
    <asp:MultiView ID="MultiView2" runat="server">
        <asp:View ID="View3" runat="server">
            <table align="center" border="1" bordercolor="#aaa" cellpadding="5" 
                cellspacing="5" 
                style="border-collapse: collapse; border-color: #aaaaaa; text-align: center" 
                width="722">
                <tr style="background-color: #eee; font-weight: bold;">
                    <td colspan="2">
                        Product Details</td>
                </tr>
                <tr>
                    <td width="310px">
                        <a class="thickbox" href="/uploads/products/<% Response.Write(getPic()); %>" 
                            title="">
                        <img src="/uploads/products/<% Response.Write(getPic()); %>" alt="" height="300px" 
         width="300px" />
                        </a><i style="font-size: 11px">Click to view larger size.</i>
                    </td>
                    <td style="text-align: left;" valign="top">
                        <asp:Label ID="lblPID" runat="server" Visible="False"></asp:Label>
                        <br />
                        <br />
                        Seller :
                        <asp:Label ID="lblSeller" runat="server" Text=""></asp:Label>
                        <br />
                        <br />
                        Product Name:
                        <asp:Label ID="lblProductName" runat="server"></asp:Label>
                        <br />
                        <br />
                        Description :
                        <asp:Label ID="lblDesc" runat="server" Text=""></asp:Label>
                        <br />
                        <br />
                        Category :
                        <asp:Label ID="lblCat" runat="server" Text=""></asp:Label>
                        <br />
                        <br />
                        Quantity Available :
                        <asp:Label ID="lblQuantity" runat="server"></asp:Label>
                        &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<br />
                        <br />
                        Price/unit:
                        <asp:Label ID="lblPrice" runat="server"></asp:Label>
                        <br />
                        <br />
                        &nbsp;
                        <br />
                        <asp:Button ID="btnApprove" runat="server" onclick="btnApprove_Click" 
                            Text="Approve Product" />
                        &nbsp;&nbsp;&nbsp;&nbsp;
                        <asp:Button ID="btnReject" runat="server" onclick="btnReject_Click" 
                            Text="Reject Product" />
                        <br />
                    </td>
                </tr>
            </table>
        </asp:View>
    </asp:MultiView>
    <br />
    <br />
    <br />
    <br />
</asp:Content>
